package org.coderjonny.dto.order;

import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;

@NoArgsConstructor
@Data
public class OrderParam {
    @NotNull(message = "用户id不能为空")
    private Long userId;
    @NotNull(message = "产品id不能为空")
    private Long productId;
    @NotNull(message = "购买产品数不能为空")
    @Min(value = 1,message = "购买产品数需要大于0")
    private Integer count;
}
